package com.siemens.industrial.app;

import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;

import java.util.Date;

/**
 * Created by David on 2016/11/16.
 */
public class DBBackupJob implements Job {

    @Override
    public void execute(JobExecutionContext jobExecutionContext) throws JobExecutionException {
        System.out.println("Hello Job for DB backup");
//        Object o = jobExecutionContext.getJobDetail().getJobDataMap().get("name");
        DBBackupImplementation dbBackupImplementation = new DBBackupImplementation();
        dbBackupImplementation.fullBackup();
        System.out.println("From DB backup job, now " + new Date());
    }
}
